<!DOCTYPE HTML>
<html>
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta name="csrf-token" content="{{ csrf_token() }}">
    <title></title>
    <link rel="stylesheet" href="/css_system/common.css"/>
    <link rel="stylesheet" href="/css_system/main.css"/>
    <link href="/js_system/jQueryUI/jquery-ui.css" rel="stylesheet">
    <link rel="stylesheet" href="/js_system/easydialog/easydialog.css"/>
    <script type="text/javascript" src="/js_system/easydialog/easydialog.js"></script>
    <script type="text/javascript" src="/js_system/cueeasy.js"></script>
    <script type="text/javascript" src="/js_system/jquery.min.js"></script>
    <script type="text/javascript" src="/js_system/common.js"></script>
    <script type="text/javascript" src="/js_system/readingparty.js"></script>
</head>
<body>
<div class="container">
    <div class="location clearfix">
        <div class="here_area fl">
            <strong>当前位置：</strong>APP管理&nbsp;&nbsp;&raquo;&nbsp;&nbsp;读书会列表
        </div>
        <div class="here_btn fr">
            <input type="button" id="DelButton" name="DelButton" class="btn btn_del" value="删 除"
                   onclick="DelDialog('确认要删除选中的读书会吗？',2)"/>
            <input type="button" name="button" class="btn btn_refresh" value="刷新"
                   onclick="location.replace(location.href);"/>
        </div>
    </div>

    <form class="filter clearfix" action="{{asset('admin_system/readingparty/index')}}" method="post">
        <dl>
            <dt>查询关键词：</dt>
            <dd>
                <input value="{{$keyword}}" class="input-text" name="KeyWords">
                {{csrf_field()}}
            </dd>
            <dd>
                <input type="submit" class="button button-primary" value="搜 索">
            </dd>
        </dl>
    </form>

    <style>
        .type-1 { color: red;  }
        .type-2 {  color: green;  }
    </style>
    <table class="dataTable">
        <tr>
            <th>选择</th>
            <th>类别</th>
            <th>读书会名称</th>
            <th>所属公司</th>
            <th>管理员</th>
            <th>会员数量</th>
            <th>申请时间</th>
            <th>操作</th>
        </tr>
        @foreach($readingparty as $data)
            <tr>
                <td><input type="checkbox" name="cbxid" value="{{$data->ReaParID}}" id="cbxid_{{$data->ReaParID}}"></td>
                <td class="type-{{$data->ReaParType}}">{{$arrayType[$data->ReaParType]}}</td>
                <td class="text-left">{{$data->ReaParName}}</td>
                <td class="text-left">{{$data->company_name}}</td>
                <td class="text-left">{{$data->UserName}}[{{$data->YourName}}]</td>
                <td><a class="btn"
                       href="{{asset('admin_system/readingparty/members?readId='.$data->ReaParID)}}">{{$data->countMember}}</a>
                </td>
                <td>{{$data->AddDate}}</td>
                <td>
                    <a class="editBtn" href="/admin_system/readingparty/index/{{$data->ReaParID}}/edit"></a>
                    <a class="uploadBtn" title="导入会员" href="{{asset('admin_system/readingparty/import_member?readId='.$data->ReaParID)}}"></a>
                    <a class="downloadBtn" title="导出会员" href="{{route('partyUpload',['id'=>$data->ReaParID])}}"></a>
                </td>
            </tr>
        @endforeach
    </table>

    <div class="pagectrl clearfix">
        {!! $readingparty->appends(['search'=>'m'])->links() !!}
    </div>
</div>
</body>
</html>